package com.wenyu.wenyuyuedu.server.homepager;

import com.wenyu.wenyuyuedu.bean.homepager.CommentBean;
import com.wenyu.wenyuyuedu.bean.homepager.Home_All_InvitationBean;
import com.wenyu.wenyuyuedu.bean.homepager.Homepage_All_item;
import com.wenyu.wenyuyuedu.bean.homepager.LikeBean;
import com.wenyu.wenyuyuedu.bean.homepager.LoginBean;

import retrofit2.Call;
import retrofit2.http.Field;
import retrofit2.http.FormUrlEncoded;
import retrofit2.http.GET;
import retrofit2.http.POST;
import retrofit2.http.Query;

/**
 * Created by Administrator on 2017/2/22.
 * 这是首页中全部页面的接口
 */

public interface Homepage_All_Server {
    /*首页--全部界面的接口*/
    @GET("/forum/index/index.html")
    Call<Homepage_All_item> getHomepageAll(@Query("token")String token,@Query("page")String page,@Query("judge")String judge);
    /*首页--全部界面详情的借口*/
    @GET("/forum/index/detail.html")
    Call<Home_All_InvitationBean> getInvitationDetail(@Query("token")String token,@Query("id")String id,@Query("page")String page);
    /*登陆的接口*/
    /*@FormUrlEncoded
    @POST("/ucenter/member/login.html")
    Call<LoginBean> getLogin(@Field("login_type") String login_type, @Field("openid")String openid, @Field("token_key")
                             String token_key, @Field("nickname")String nickname, @Field("type")String type
                                , @Field("path")String path);
    */
    @FormUrlEncoded
    @POST("/ucenter/member/login.html")
    Call<LoginBean> getLogin(@Field("login_type") String login_type, @Field("openid") String openid, @Field("token_key")
            String token_key, @Field("nickname") String nickname, @Field("type") int type, @Field("path") String path);
    /*点赞的接口*/
    @GET("/forum/index/dobookmark.html")
    Call<LikeBean> getLike(@Query("token")String token,@Query("object_id")int object_id,@Query("type")int type);
    /*评论的接口*/
    @GET("/forum/index/postComment.html")
    Call<CommentBean> getComment(@Query("token")String token,@Query("parent_uid")String parent_uid,
                                 @Query("to_uid")String to_uid,@Query("parent_id")String parent_id,
                                 @Query("post_id")String post_id,@Query("content")String content);
}
